Skip to content

pr revisit expected failed kotl tests plus updates#921

Open
matsl wants to merge 4 commits intomasterfrom
pr_revisit_expected_failed_kotl_tests_plus_updates
Open

pr revisit expected failed kotl tests plus updates#921
matsl wants to merge 4 commits intomasterfrom
pr_revisit_expected_failed_kotl_tests_plus_updates

Conversation

@matsl
Copy link
Copy Markdown
Collaborator

@matsl matsl commented Mar 26, 2026

What

  • Fix problem with removing single tree with one child
  • Add kotl-mode:erase-buffer
  • Replace expected-result failed with FIXME comment
  • Add ChangeLog

Why

This PR changed addresses the one remaining test in the suite where we
have expected failed. There is a problem with kotl-mode:split-cell
that introduces an extra empty line in a case. We have not attempted
to fix that for a long time so I document the problem with a FIXME
comment and change the verification so that the test succeeds.

While working on the test I noticed an issue with kotl-mode:kill-tree
that is fixed here with a test case.

I also added a new function, kotl-mode:erase-buffer, plus a test case
for it. I think it makes writing test cases easier when we can erase a
buffer to start all over again. A pattern we have started to use more
of.

The PR is split in multiple commits for easier review.

matsl added 4 commits March 26, 2026 22:38
* kotl/kotl-mode.el (kotl-mode:kill-tree): Move to valid position
    first when inital cell is created.

* test/kotl-mode-tests.el (kotl-mode--kill-tree-first-and-only-tree):
    Verify change works.
* kotl/kotl-mode.el (kotl-mode:erase-buffer): Add
    kotl-mode:erase-buffer to make it easier to reuse buffers in tests.

* test/kotl-mode-tests.el (kotl-mode--erase-buffer): Add test for new
    function.
* test/kotl-mode-tests.el (kotl-mode-split-cell): Remove
    expected-result failed but add FIXME comment where
    kotl-mode:split-cell fails.
    Use kotl-mode:erase-buffer for clearer reuse of test buffer.
@matsl matsl requested a review from rswgnu March 26, 2026 22:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant